html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}
#start-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 1);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 1000; /* 确保在最上层 */
}

#start-button {
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s; /* 添加过渡效果 */
}

#start-button:hover {
    background-color: #007bff; /* 悬停时改变背景颜色 */
    color: white; /* 悬停时改变文字颜色 */
}

#start-button:active {
    transform: scale(0.95); /* 点击时缩小按钮 */
}
#game-container {
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

#game-canvas {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

#game-sidebar {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 10px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    min-width: 200px;
    backdrop-filter: blur(10px);
    z-index: 1000;
}

#info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: #f0f2f5;
    border-radius: 8px;
}

.info-label {
    font-weight: bold;
    color: #333;
}

.info-value {
    font-size: 1.2em;
    color: #2196F3;
}

button {
    padding: 12px 24px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #2196F3;
    color: white;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

button:hover {
    background: #1976D2;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

button:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#pause-btn {
    background: #FF9800;
}

#pause-btn:hover {
    background: #F57C00;
}

#restart-btn {
    background: #4CAF50;
}

#restart-btn:hover {
    background: #388E3C;
}

#game-sidebar:hover {
    background: rgba(255, 255, 255, 0.95);
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
}

.level-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.level-btn {
    flex: 1;
    padding: 8px;
    font-size: 14px;
    background: #3F51B5;
}

.level-btn:hover {
    background: #303F9F;
}

.level-btn.active {
    background: #303F9F;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
    transform: translateY(0);
}